﻿using AntdUI;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Lima.ResumeSys.Models
{
    public class PerFile : NotifyProperty
    {
        private string perFileId;
        private string perNo;
        private string fileName;
        private string fileContent;
        private string fileSize;
        private string fileSuffix;
        private string fileUrl;
        private string creator;
        public DateTime CreateTime { get; set; } = DateTime.Now;
        public string CreateTimeText { get; set; }
        private CellLink[] cellLinks;
        /// <summary>
        /// PerFileId
        /// </summary>
        public string PerFileId
        {
            get { return perFileId; }
            set
            {
                if (perFileId == value) return;
                perFileId = value;
                OnPropertyChanged(nameof(PerFileId));
            }
        }

        /// <summary>
        /// 人员编号
        /// </summary>
        public string PerNo
        {
            get { return perNo; }
            set
            {
                if (perNo == value) return;
                perNo = value;
                OnPropertyChanged(nameof(PerNo));
            }
        }

        /// <summary>
        /// 文件名
        /// </summary>
        public string FileName
        {
            get { return fileName; }
            set
            {
                if (fileName == value) return;
                fileName = value;
                OnPropertyChanged(nameof(FileName));
            }
        }

        /// <summary>
        /// 文件内容
        /// </summary>
        public string FileContent
        {
            get { return fileContent; }
            set
            {
                if (fileContent == value) return;
                fileContent = value;
                OnPropertyChanged(nameof(FileContent));
            }
        }
        public string FileSize
        {
            get { return fileSize; }
            set
            {
                if (fileSize == value) return;
                fileSize = value;
                OnPropertyChanged(nameof(FileSize));
            }
        }
        
        /// <summary>
        /// 文件后缀
        /// </summary>
        public string FileSuffix
        {
            get { return fileSuffix; }
            set
            {
                if (fileSuffix == value) return;
                fileSuffix = value;
                OnPropertyChanged(nameof(FileSuffix));
            }
        }
        /// <summary>
        /// 文件Url
        /// </summary>
        public string FileUrl
        {
            get { return fileUrl; }
            set
            {
                if (fileUrl == value) return;
                fileUrl = value;
                OnPropertyChanged(nameof(FileUrl));
            }
        }

        /// <summary>
        /// 创建人
        /// </summary>
        public string Creator
        {
            get { return creator; }
            set
            {
                if (creator == value) return;
                creator = value;
                OnPropertyChanged(nameof(Creator));
            }
        }
        public CellLink[] CellLinks
        {
            get { return cellLinks; }
            set
            {
                if (cellLinks == value) return;
                cellLinks = value;
                OnPropertyChanged(nameof(CellLinks));
            }
        }

        public class QueryPerFileModel
        {
            public string PerNo { get; set; }

        }
    }
}
